package Leetcode;

public class Demo1 {


    public static void main(String[] args) {
        int fib = fib1.fib(300);
        int[] arr=new int[100];
        int len=arr.length;
    }
}
class fib1{
    public static int[] arr=new int[100000];
    public static int fib(int n) {
        if(n==1||n==2){
            return 1;
        }
        if(arr[n]==0){
            arr[n]=fib(n-1)+fib(n-2);
            return arr[n];
        }else{
            return arr[n];
        }

    }
}
